.upload-container{
    position: relative;

    .upload-list{
        position: relative;
        display: flex;
        flex-wrap: wrap;
        box-sizing: border-box;
        gap: 8px;
        line-height: 1.6;

        .upload-item-box{
            display: inline-block;
            width: 100px;
            height: 100px;
            vertical-align: top;
    
            .upload-item{
                position: relative;
                width: 100%;
                height: 100%;
                border-radius: 8px;
                border: 1px solid var(--main-4);
                overflow: hidden;
                cursor: pointer;

                .done, .uploading, .error, .ready{
                    width: 100%;
                    height: 100%;
                    border-color: var(--main-8);

                    .actions{
                        position: absolute;
                        top: 0;
                        left: 0;
                        width: 100%;
                        height: 100%;
                        z-index: 3;
                        display: none;
                        background-color: rgba(var(--black-alpha), 0.45);

                        .btn{
                            width: 100%;
                            display: flex;
                            align-items: center;
                            justify-content: center;

                            .button{
                                position: relative;
                                width: 24px;
                                height: 24px;
                                margin: 0 4px;
                                display: flex;
                                align-items: center;
                                justify-content: center;
                                border-radius: 4px;
                                color: var(--white);
                                cursor: pointer;

                                &:hover{
                                    background: rgba(var(--gray-6-alpha), 0.8);
                                }
                            }
                        }
                    }

                    &:hover{
                        border-color: var(--main-8);

                        .actions{
                            display: flex;
                        }
                    }
                }

                .done{
                    &>img{
                        position: relative;
                        width: 100%;
                        height: 100%;
                        object-fit: scale-down;
                    }

                    .set{
                        position: absolute;
                        top: 8px;
                        right: 8px;
                        padding: 4px 8px;
                        border-radius: 12px;
                        font-size: 12px;
                        color: var(--white);
                        background: rgba(var(--gray-6-alpha), 0.8);
                        cursor: pointer;
                        user-select: none;
                        z-index: 3;
                        line-height: 1em;

                        &.primary{
                            background: var(--main-6);
                        }
                    }
                }

                .uploading, .error, .ready{
                    position: relative;
                    height: 100%;
                    display: flex;
                    align-items: center;
                    justify-content: center;
                    font-size: 12px;

                    p{
                        word-break: break-all;
                        max-height: 52px;
                        overflow: auto;

                        &::-webkit-scrollbar{display: none;}
                    }
                }
                .uploading{
                    .holder-image{
                        width: 100%;
                        opacity: 0.1;
                    }

                    .percent{
                        position: absolute;
                        top: 0;
                        left: 0;
                        height: 100%;
                        width: 100%;
                        display: flex;
                        align-items: center;
                        justify-content: center;
                    }
                }
                .error{
                    color: var(--error);
                }
                .ready{
                    color: var(--warning);
                    flex-direction: column;
                }
            }

            &.upload-button{
                text-align: center;
                background-color: var(--ant-color-fill-alter);
                border: var(--ant-line-width) dashed var(--ant-color-border);
                border-radius: var(--ant-border-radius-lg);
                cursor: pointer;
                transition: border-color 0.2s;

                .rt-upload{
                    height: 100%;
                    display: flex;
                    flex-direction: column;
                    align-items: center;
                    justify-content: center;
                }

                &:hover{
                    border-color: var(--rt-primary-color);
                }
            }

            &.circle{
                border-radius: 50%;
                padding: 0;
                overflow: hidden;

                .upload-item{
                    border: 0;

                    .done{
                        &>img{
                            object-fit: cover;
                        }
                    }
                }
            }
        }
    }

}